]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
status/backlight: Sync checked on level changes
authorFlorian Müllner <fmuellner@gnome.org>
Sat, 5 Aug 2023 19:12:55 +0000 (21:12 +0200)
committerMarge Bot <marge-bot@gnome.org>
Sat, 5 Aug 2023 20:02:57 +0000 (20:02 +0000)
Since switching to property bindings/notifications, value changes
only happen on actual changes, so we cannot rely on them as the sole
source of updating the checked state.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2862>

js/ui/status/backlight.js

index 4faf4fab4239f781a6c89da56457e9257e1be909..74df6a6cc10297fe9a2a97e9d4907ec9357264fb 100644 (file)
@@ -127,6 +127,7 @@ const DiscreteItem = GObject.registerClass({
         this._levelButtons.get('off').visible = this.nLevels > 0;
         this._levelButtons.get('high').visible = this.nLevels > 1;
         this._levelButtons.get('low').visible = this.nLevels > 2;
+        this._syncChecked();
     }
 
     _syncChecked() {